<?php
/**
 * Pfinal数据库链接默认插件
 * @author huangyusheng
 * @since 2014-3-20
 * @package project_name.package_name
 */
class Pfinal_Plugin_DbConnection implements Pfinal_Plugin_Interface {
	
	protected $adapter;
	
	protected $params;
	
	/**
	 * @return the $adapter
	 */
	public function getAdapter() {
		return $this->adapter;
	}

	/**
	 * @param field_type $adapter
	 */
	public function setAdapter($adapter) {
		$this->adapter = $adapter;
	}

	public function __construct($params){
		$this->adapter = new Pfinal_Model_Adapter_RMDBS();
		$this->params = $params;
		
	}
	/*
	 * (non-PHPdoc) @see Pfinal_Plugin_Interface::start()
	 */
	public function start() {
		// TODO Auto-generated method stub
		var_dump($this->params);
		$this->adapter->init($this->params);
	}
	
	/*
	 * (non-PHPdoc) @see Pfinal_Plugin_Interface::stop()
	 */
	public function stop() {
		// TODO Auto-generated method stub
	}
	
	// TODO - Insert your code here
}

?>